<?php
namespace Home\Controller;

class RankController extends CommonController {
    public function index(){

        $cslist = M('user')->field('nickname,avatar,rank')->where(array('status'=>1,'grade_id'=>5))->order('rank')->limit(10)->select();
        $zslist = M('user')->field('nickname,avatar,rank')->where(array('status'=>1,'grade_id'=>4))->order('rank')->limit(10)->select();
        $hjlist = M('user')->field('nickname,avatar,rank')->where(array('status'=>1,'grade_id'=>3))->order('rank')->limit(10)->select();

        $this->assign('cslist',$cslist);
        $this->assign('zslist',$zslist);
        $this->assign('hjlist',$hjlist);
        $this->assign('mark','rank');
        $this->display();
    }
}
